#include <string>

#include "singleton.h"

SingleString* SingleString::m_singleString = NULL;

SingleString::SingleString()
{
	m_str = "I'm the single string.";
}

SingleString* SingleString::Instance()
{
	if (NULL == m_singleString)
	{
		// static volatile Locker locker;
		// locker.Lock();

		if (NULL == m_singleString)
		{
			m_singleString = new SingleString();

			static SingleStringCleaner cleaner;
		}

		// locker.Unlock();
	}

	return m_singleString;
}

const std::string* SingleString::GetString()
{
	return &m_str;
}
